package com.xmtlxx.wms.mapper;

import com.xmtlxx.common.core.mapper.BaseMapperPlus;
import com.xmtlxx.wms.domain.InventoryDtl;
import com.xmtlxx.wms.domain.bo.InventoryDtlBo;
import com.xmtlxx.wms.domain.vo.InventoryDtlVo;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * 盘点明细Mapper接口
 *
 * @author xmtlxx
 * @date 2022-08-15
 */
public interface InventoryDtlMapper extends BaseMapperPlus<InventoryDtlMapper, InventoryDtl, InventoryDtlVo> {
    /**
     * 根据条件分页查询盘点明细
     *
     * @param inventoryDtl 盘点明细
     * @return Page InventoryDtl
     */
//    @DataPermission({
//        @DataColumn(key = "tenantName", value = "i.create_by"),
//        @DataColumn(key = "deptName", value = "i.dept_id"),
//        @DataColumn(key = "userName", value = "i.create_by")
//    })
    Page<InventoryDtlVo> selectPageInventoryDtlList(@Param("page") Page<InventoryDtl> page,@Param("inventoryDtl") InventoryDtlBo inventoryDtl);

    /**
     * 查询盘点明细列表
     *
     * @param inventoryDtl 盘点明细
     * @return 盘点明细集合
     */
//    @DataPermission({
//        @DataColumn(key = "tenantName", value = "i.create_by"),
//        @DataColumn(key = "deptName", value = "i.dept_id"),
//        @DataColumn(key = "userName", value = "i.create_by")
//    })
    List<InventoryDtlVo> selectInventoryDtlList(@Param("inventoryDtl") InventoryDtlBo inventoryDtl);

    List<InventoryDtlVo> selectNewInventoryDtlList(@Param("id") String id);

    InventoryDtlVo selectInventoryDtlVoByID(String id);
}
